package tech.aistar.corejava.day11.homework.ShoppingCar;

/**
 * @Author: lya
 * @Description: 本类的作用描述:
 * @CreateDate: 2019/7/29
 * @Version: 1.0
 */
public class TestProduct {
    public static void main(String[] args) {
        ICarDao car = new CarDaoImlp();

        Product p1 = new Product(1, "电脑1", 100);
        Product p2 = new Product(2, "电脑2", 200);
        Product p3 = new Product(3, "电脑3", 300);
        Product p4 = new Product(4, "电脑4", 400);
        Product p5 = new Product(5, "电脑5", 500);
        Product p6 = new Product(6, "电脑6", 600);
        Product p7 = new Product(7, "电脑7", 800);
        Product p8 = new Product(8, "电脑8", 700);
        Product p9 = new Product(9, "电脑9", 900);
        Product p10 = new Product(10, "电脑10", 1000);
        Product p11 = new Product(11, "电脑11", 1500);
        Product p12 = new Product(12, "电脑12", 2000);

        car.insert(p1);
        car.insert(p2);
        car.insert(p3);
        car.insert(p4);
        car.insert(p5);
        car.insert(p6);
        car.insert(p7);
        car.insert(p8);
        car.insert(p9);
        car.insert(p10);
        car.insert(p11);
        car.insert(p12);

        car.select(5);
        car.delete(6);
        car.update("电脑10","电视",13,5600.0);
        System.out.println(car.findAll());
    }
}
